import request from "@/utils/request";

// 添加培训证书
export function addTrainCertificate(data) {
	return request({
		url: "/trainCertificate/add",
		method: "post",
		data: data,
	});
}

// 分页查询
export function getPage(params) {
	return request({
		url: "/adverts/getPage/noAuth",
		method: "get",
		params: params,
	});
}

// 新增保存
export function addSave(data) {
	return request({
		url: "adverts/add",
		method: "post",
		data: data,
	});
}

// 编辑保存
export function editSave(data) {
	return request({
		url: "/adverts/upd",
		method: "post",
		data: data,
	});
}

// 通过key删除
export function delAdverts(data) {
	return request({
		url: `/adverts/del`,
		method: "post",
		data: data,
	});
}

// 通过key查询
export function getDetailsByKey(params) {
	return request({
		url: "/adverts/getByKey/noAuth",
		method: "get",
		params: params,
	});
}
